<template>
  <div class="jobs">
    <el-card shadow="hover">
      <div slot="header">
        <el-button size="small" type="primary" @click="getJobs" icon="el-icon-refresh">刷新</el-button>
      </div>
    </el-card>
  </div>
</template>
<script>
import {getStudentJobApi} from '@/api/qingongjianxue'
export default {
  computed: {
    userInfo(){
      const info = this.$store.state.app.user_info
      return info
    }
  },
  data() {
    return {
      jobs: []
    }
  },
  methods: {
    async getJobs(){
      const res = await getStudentJobApi(this.userInfo.address)
      this.jobs = res.data
    }
  },
  mounted() {
    this.getJobs()
  }
}
</script>
<style scoped lang="scss">
.jobs{
  padding: 14px;
}
</style>
